//
//  DrawerView.m
//  NanNote
//
//  Created by 郑楠 on 15/5/21.
//  Copyright (c) 2015年 ___NANteam___. All rights reserved.
//

#import "DrawerView.h"

#define WIDTH self.frame.size.width
#define HEIGHT self.frame.size.height

@implementation DrawerView

- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        UIButton *trashBtn = [UIButton buttonWithType:UIButtonTypeSystem];
        trashBtn.frame = CGRectMake(20, 100, 110, 40);
        trashBtn.layer.borderWidth = 1;
        trashBtn.layer.cornerRadius = 5;
        [trashBtn setTitle:@"trash" forState:UIControlStateNormal];
        [trashBtn addTarget:self action:@selector(pushToTrashViewController:) forControlEvents:UIControlEventTouchUpInside];
        [self addSubview:trashBtn];
        self.backgroundColor = [UIColor orangeColor];
    }
    return self;
}

- (void)pushToTrashViewController:(UIButton *)btn {
    [self.delegate pushToTrash];
}

@end
